USE [BVVD]
GO

/****** Object:  Table [dbo].[LST_HOCVIEN]    Script Date: 5/31/2013 4:48:15 AM ******/
SET ANSI_NULLS ON
GO

SET QUOTED_IDENTIFIER ON
GO

SET ANSI_PADDING ON
GO

CREATE TABLE [dbo].[LST_HOCVIEN](
	[RECID] [int] IDENTITY(1,1) NOT NULL,
	[NAMHOC] [varchar](15) NOT NULL,
	[MAHV] [varchar](15) NOT NULL,
	[HODEM] [nvarchar](50) NULL,
	[TENHV] [nvarchar](50) NULL,
	[NGAYSINH] [date] NULL,
	[GIOITINH] [nvarchar](50) NULL,
	[LOAIGIAY] [int] NULL,
	[SOCMND] [varchar](50) NULL,
	[NGAYCAP] [date] NULL,
	[NOICAP] [nvarchar](50) NULL,
	[DIACHI] [nvarchar](300) NULL,
	[HOKHAU] [nvarchar](300) NULL,
	[QUEQUAN] [nvarchar](100) NULL,
	[TEL] [varchar](50) NULL,
	[MOBILE] [varchar](50) NULL,
	[EMAIL] [varchar](50) NULL,
	[QUOCTICH] [nvarchar](50) NULL,
	[DANTOC] [nvarchar](50) NULL,
	[TONGIAO] [nvarchar](50) NULL,
	[COQUANCT] [nvarchar](200) NULL,
	[CHUCVU] [nvarchar](100) NULL,
	[CHUCDANH] [nvarchar](100) NULL,
	[TRINHDO] [nvarchar](100) NULL,
	[CHUYENMON] [nvarchar](100) NULL,
	[DANGVIEN] [int] NULL,
	[NGAYVAODANG] [date] NULL,
	[DOANVIEN] [int] NULL,
	[NGAYDOANVIEN] [date] NULL,
	[THUONGBINH] [int] NULL,
	[CONLIETSY] [int] NULL,
	[THAMNIEN_Y] [nvarchar](50) NULL,
	[THAMNIEN_M] [nvarchar](50) NULL,
	[KHENTHUONG] [ntext] NULL,
	[KYLUAT] [ntext] NULL,
	[PICTURE] [image] NULL,
	[TRANGTHAI] [varchar](15) NULL,
	[GHICHU] [ntext] NULL,
PRIMARY KEY CLUSTERED 
(
	[RECID] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY],
UNIQUE NONCLUSTERED 
(
	[MAHV] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]

GO

SET ANSI_PADDING OFF
GO

ALTER TABLE [dbo].[LST_HOCVIEN] ADD  DEFAULT ((0)) FOR [LOAIGIAY]
GO

ALTER TABLE [dbo].[LST_HOCVIEN] ADD  DEFAULT ((0)) FOR [DANGVIEN]
GO

ALTER TABLE [dbo].[LST_HOCVIEN] ADD  DEFAULT ((0)) FOR [DOANVIEN]
GO

ALTER TABLE [dbo].[LST_HOCVIEN] ADD  DEFAULT ((0)) FOR [THUONGBINH]
GO

ALTER TABLE [dbo].[LST_HOCVIEN] ADD  DEFAULT ((0)) FOR [CONLIETSY]
GO

ALTER TABLE [dbo].[LST_HOCVIEN] ADD  DEFAULT ((0)) FOR [THAMNIEN_Y]
GO

ALTER TABLE [dbo].[LST_HOCVIEN] ADD  DEFAULT ((0)) FOR [THAMNIEN_M]
GO

ALTER TABLE [dbo].[LST_HOCVIEN] ADD  DEFAULT ('1') FOR [TRANGTHAI]
GO

